package org.jeecgframework.web.service;
import org.jeecgframework.core.common.service.CommonService;
import org.jeecgframework.web.system.pojo.base.CbsInspectionAppointmentEntity;
import org.jeecgframework.web.util.SectionEnum;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

public interface CbsInspectionAppointmentServiceI extends CommonService{
	
 	public <T> void delete(T entity);
 	
 	public <T> Serializable save(T entity);
 	
 	public <T> void saveOrUpdate(T entity);
 	
 	/**
	 * 默认按钮-sql增强-新增操作
	 * @param id
	 * @return
	 */
 	public boolean doAddSql(CbsInspectionAppointmentEntity t);
 	/**
	 * 默认按钮-sql增强-更新操作
	 * @param id
	 * @return
	 */
 	public boolean doUpdateSql(CbsInspectionAppointmentEntity t);
 	/**
	 * 默认按钮-sql增强-删除操作
	 * @param id
	 * @return
	 */
 	public boolean doDelSql(CbsInspectionAppointmentEntity t);

	/**
	 * 生成巡检预约id
	 * @return
	 */
	public String genInAppId(CbsInspectionAppointmentEntity t);

    public List<CbsInspectionAppointmentEntity> findAppointmentWithCinema(String cinemaId);

    public Map genMapVo(CbsInspectionAppointmentEntity app);

    List<CbsInspectionAppointmentEntity> findAppointmentWithCinemaAndSn(String cinemaId,String searchContent);

    /**
     * 检查提供的sn设备是否已经在巡检预约审批中
     * @param snNums 设备id1,设备id2
     * @return 如果有正在审批中的设备，返回设备的sn
     */
    public String checkSnIfInAppoint(String snNums);

    public boolean checkSection(int section);

    public int[] generateExpectYearsSelect();

    public List<SectionEnum> generateExpectSectionSelect(int year);

}
